<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org">

<head>
    <meta charset="utf-8">
    <title></title>
    <meta name="renderer" content="webkit">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
    <meta name="apple-mobile-web-app-status-bar-style" content="black">
    <meta name="apple-mobile-web-app-capable" content="yes">
    <meta name="format-detection" content="telephone=no">
    <link rel="stylesheet" href="../static/userinfoPrivate/layui/css/layui.css" media="all">
    <link rel="stylesheet" href="../static/css/thesame.css" media="all">
    <link rel="stylesheet" href="../static/css/footer.css" media="all">
    <link rel="stylesheet" href="../static/css/drugs/rightCon.css" media="all">
    <link rel="stylesheet" href="../static/css/drugs/tree.css" media="all">
    <style>
    </style>
</head>

<body class="layui-layout-body">
<div class="layui-body">
    <div class="add-title pad25px"><span class="mr10px cursor return"><img src="../static/img/return_icon.png"></span><span>药物登记详情</span></div>
    <div class="new-add-box new-add-box-width bgWhite box-shadows border-radius4">
        <div class="new-add-box-scroll">
            <div class="mar25px">
                <nav>
                    <div class="mb15px">
                        <span class="fb" id="meicineName"></span>
                        <p class="table-list-age inline-block" id="jingshen" style="display: none"><span class="span-bgYellow ml15px">精神药物</span></p>
                    </div>
                    <ul class="lh45px details-ul">
                        <li>
                            <span class="fb">登记时间：</span><em id="registerDate"></em>
                        </li>
                        <li>
                            <span class="fb">厂家：</span><em id="manufactureFactory"></em>
                        </li>
                        <li>
                            <span class="fb">规格：</span><em id="specification"></em>
                        </li>
                        <li>
                            <span class="fb">数量：</span><em id="medicineCount"></em>
                        </li>
                        <li>
                            <span class="fb">批号：</span><em id="batchNumber"></em>
                        </li>
                        <li>
                            <span class="fb">有效期：</span><em id="validityDate"></em>
                        </li>
                        <li>
                            <span class="fb">服法：</span><em id="useMethod"></em>
                        </li>
                        <li>
                            <span class="fb">药量结束时间：</span><em id="userEndDtate"></em>
                        </li>
                        <li>
                            <span class="fb">家属姓名：</span><em id="familyName"></em>
                        </li>
                        <li>
                            <span class="fb">经办人：</span><em id="userNo"></em>
                        </li>
                    </ul>
                </nav>
            </div>
        </div>
    </div>
</div>
<div class="layui-footer layui-footer-one">
    <div class="btn-con textCenter">
        <span class="btn-one cursor return">返&nbsp;回</span>
        <!--        <span class="btn-two">提&nbsp;交</span>-->
    </div>
</div>
<script src="../static/js/jquery-2.1.3.min.js"></script>
<script src="../static/layui/layui.js" charset="utf-8"></script>
<script th:inline="javascript">

    $(function () {
        $(".return").click(function () {
            window.history.back();
        })

        getData();
    });

    var id = [[${id}]]

    function getData() {
        var data = {id: id};
        $.ajax({
            url: "../medicine/getUserMedicineById",
            type: "get",
            async: false,
            dataType: "json",
            data: data,
            success: function (data) {
                if (data.code == 200) {
                    if (data.data.meicineNature == 102) {
                        $("#jingshen").css("display", "");
                    }
                    $("#meicineName").text(data.data.meicineName)
                    $("#manufactureFactory").text(data.data.manufactureFactory)
                    $("#specification").text(data.data.specification)
                    $("#medicineCount").text(data.data.medicineCount)
                    $("#batchNumber").text(data.data.batchNumber)
                    $("#validityDate").text(data.data.validityDate)
                    $("#userEndDtate").text(data.data.userEndDtate)
                    $("#familyName").text(data.data.familyName)
                    $("#userNo").text(data.data.tellerNo)
                    $("#registerDate").text(data.data.registerDate)
                    $("#useMethod").text(data.data.useMethod)
                }
            }
        })
    }
</script>
</body>

</html>
